package springboot.study.project.service;

import springboot.study.project.model.Clazz;
import springboot.study.project.model.Department;
import springboot.study.project.model.Major;

import java.util.List;
import java.util.Map;

/**
 * @InterfaceName: CommonService
 * @Description: 通用相关接口
 * @Author: liu-hao
 * @Date: 2021-04-11 15:34
 * @Version: 1.0
 **/
public interface CommonService {

    /**
     * 获取所有系
     *
     * @return
     */
    List<Department> getAllDept();

    boolean addDept(Department department);

    boolean removeDept(String deptId);

    boolean modifyDept(Department department);

    Map<String, Object> findDeptInfo(String deptName, int offset, int pageSize);

    /**
     * 获取指定院系下面的专业
     *
     * @param deptId
     * @return
     */
    List<Major> getMajorByDeptId(String deptId);

    boolean addMajor(Major major);

    boolean removeMajor(String majorId);

    boolean modifyMajor(Major major);

    Map<String, Object> findMajorInfo(String majorName, int offset, int pageSize);

    /**
     * 获取指定专业下的班级
     *
     * @param majorId
     * @return
     */
    List<Clazz> getClazzByMajorId(String majorId);

    boolean addClazz(Clazz clazz);

    boolean removeClazz(String clazzId);

    boolean modifyClazz(Clazz clazz);

    Map<String, Object> findClazzInfo(String clazzName, int offset, int pageSize);


}
